<?php //strip
/**
 * Form implementation for a single playground.
 * 
 * @package odReservationsWpPlugin
 * @subpackage odReservationsWpPlugin_Forms
 * @author Ondrej Donek <ondrejd@gmail.com>
 */
class odReservationsWpPlugin_Forms_Playground extends odWpPlugin_Form
{
  /**
   * Constructor - set up the playground form.
   * 
   * @param string $aName Name of the form.
   * @param string $aDescription Description of the form.
   * @param array $aFields Array with form fields.
   * @param string $aDecorator Optional. Defaultly self::DECORATOR_SIMPLE.
   * @param odWpPlugin_Model_Interface|null $mModel
   * @return void
   */
	public function __construct()
	{
		parent::__construct(
		  'reservations_playground_form', 
		  '', 
		  array(
	      'ID' => array(
	        'type' => self::TYPE_HIDDEN,
	        'label' => null
	      ),
	      'op' => array(
	        'type' => self::TYPE_HIDDEN,
	        'label' => null
	      ),
	      'title' => array(
	        'type' => self::TYPE_TEXT, 
	        'label' => __('Název:', odReservationsWpPlugin::TEXTDOMAIN),
	        'required' => true
	      ),
	      'description' => array(
	        'type' => self::TYPE_TINYMCE, 
	        'label' => __('Popis:', odReservationsWpPlugin::TEXTDOMAIN)
	      ),
	      'max_players' => array(
	        'type' => self::TYPE_TEXT, 
	        'label' => __('Maximální počet hrářů pro hru:', odReservationsWpPlugin::TEXTDOMAIN),
	        'style' => 'width: 50px;'
	      ),
	      'hours_per_game' => array(
	        'type' => self::TYPE_TEXT, 
	        'label' => __('Jedna hra trvá hodin:', odReservationsWpPlugin::TEXTDOMAIN),
	        'style' => 'width: 50px;'
	      ),
	      'start_times' => array(
	        'type' => self::TYPE_ARRAY,
	        'label' => __('Startovací hodiny:', odReservationsWpPlugin::TEXTDOMAIN),
	        'array_desc' => array(
	          8  => array('label' => '8:00', 'type' => self::TYPE_CHECKBOX),
	          9  => array('label' => '9:00', 'type' => self::TYPE_CHECKBOX),
	          10 => array('label' => '10:00', 'type' => self::TYPE_CHECKBOX),
	          11 => array('label' => '11:00', 'type' => self::TYPE_CHECKBOX),
	          12 => array('label' => '12:00', 'type' => self::TYPE_CHECKBOX),
	          13 => array('label' => '13:00', 'type' => self::TYPE_CHECKBOX),
	          14 => array('label' => '14:00', 'type' => self::TYPE_CHECKBOX),
	          15 => array('label' => '15:00', 'type' => self::TYPE_CHECKBOX),
	          16 => array('label' => '16:00', 'type' => self::TYPE_CHECKBOX),
	          17 => array('label' => '17:00', 'type' => self::TYPE_CHECKBOX),
	          18 => array('label' => '18:00', 'type' => self::TYPE_CHECKBOX),
	          19 => array('label' => '19:00', 'type' => self::TYPE_CHECKBOX),
	          20 => array('label' => '20:00', 'type' => self::TYPE_CHECKBOX),
	          21 => array('label' => '21:00', 'type' => self::TYPE_CHECKBOX)
	        )
	      ),
	      'deleted' => array(
	        'type' => self::TYPE_CHECKBOX,
	        'label' => __('Smazán:', odReservationsWpPlugin::TEXTDOMAIN),
	        'disabled' => true
	      )
	    ), 
	    self::DECORATOR_TABLE, 
	    null
		);
	}
} // End of odReservationsWpPlugin_Forms_Playground
